import unittest
from test.test_weixin import TestWeiXin
import parameterized

datas = [["大彻大悟","13812345678","abc123456"],["幸福人生","13812345679","abc1234"]]

class UnitWeiXinTest(unittest.TestCase):

    @classmethod
    def setUpClass(cls):
        cls.tw = TestWeiXin()
    @classmethod
    def tearDownClass(cls):
        pass

    def setUp(self):
        self.tw.open()

    def tearDown(self):
        self.tw.driver.quit()

    @parameterized.parameterized.expand(datas)  # [[],[]]
    def test_register(self, name,phone, pwd):
        text = self.tw.main(name,phone, pwd)
        self.assertIn("Thank you", text)



if __name__ == '__main__':
    unittest.main(verbosity=2)
